﻿namespace MhAdmin.System;

/// <summary>
/// 系统邮件
///</summary>
[SugarTable("msg_mail", TableDescription = "系统邮件")]
[Tenant(SqlsugarConst.DB_Default)]
public class MsgMail : DataEntityBase
{
    /// <summary>
    /// 邮件引擎
    /// </summary>
    [SugarColumn(ColumnName = "MailType", ColumnDescription = "邮件引擎", Length = 20, IsNullable = false)]
    public string MailType { get; set; }

    /// <summary>
    /// 发送方式
    /// </summary>
    [SugarColumn(ColumnName = "SendType", ColumnDescription = "发送方式", Length = 20, IsNullable = true)]
    public string SendType { get; set; }

    /// <summary>
    /// 发件人邮箱
    /// </summary>
    [SugarColumn(ColumnName = "SenderMail", ColumnDescription = "发件人邮箱", Length = 200, IsNullable = true)]
    public string SenderMail { get; set; }

    /// <summary>
    /// 收件人邮箱
    /// </summary>
    [SugarColumn(ColumnName = "ReceiverMail", ColumnDescription = "收件人邮箱", Length = 200, IsNullable = false)]
    public string ReceiverMail { get; set; }

    /// <summary>
    /// 执行状态
    /// </summary>
    [SugarColumn(ColumnName = "ExeStatus", ColumnDescription = "执行状态", Length = 20, IsNullable = true)]
    public string ExeStatus { get; set; }

    /// <summary>
    /// 发送失败原因
    /// </summary>
    [SugarColumn(ColumnName = "ErrorMsg", ColumnDescription = "发送失败原因", Length = 300, IsNullable = true)]
    public string ErrorMsg { get; set; }

    /// <summary>
    /// 邮件主题
    /// </summary>
    [SugarColumn(ColumnName = "MailSubject", ColumnDescription = "邮件主题", Length = 200, IsNullable = true)]
    public string MailSubject { get; set; }

    /// <summary>
    /// 邮件正文
    /// </summary>
    [SugarColumn(ColumnName = "MailBody", ColumnDescription = "邮件正文", Length = 500, IsNullable = true)]
    public string MailBody { get; set; }

    /// <summary>
    /// 模板名称
    /// </summary>
    [SugarColumn(ColumnName = "MailModel", ColumnDescription = "模板名称", Length = 200, IsNullable = true)]
    public string MailModel { get; set; }

    /// <summary>
    /// 标签名
    /// </summary>
    [SugarColumn(ColumnName = "MailLabel", ColumnDescription = "标签名", Length = 200, IsNullable = true)]
    public string MailLabel { get; set; }

    /// <summary>
    /// 发件人昵称
    /// </summary>
    [SugarColumn(ColumnName = "MailNickname", ColumnDescription = "发件人昵称", Length = 50, IsNullable = true)]
    public string MailNickname { get; set; }
}
